﻿
using K9Nano.Application.Dtos;

namespace K9Nano.Application.Organization;

public interface IOrganizationUnitAppService
{
    Task<OrganizationUnitDto> CreateAsync(OrganizationUnitCreateDto input, CancellationToken cancellation);
    Task DeleteAsync(long id, CancellationToken cancellation);
    Task<OrganizationUnitDto?> GetAsync(long id, CancellationToken cancellation);
    Task<IReadOnlyList<OrganizationUnitDto>> GetChildrenAsync(long? parentId, bool recursive, CancellationToken cancellation);
    Task<PagedResultDto<OrganizationUnitDto>> QueryAsync(OrganizationUnitQueryDto dto, CancellationToken cancellation);
    Task<OrganizationUnitDto> UpdateAsync(OrganizationUnitEditDto input, CancellationToken cancellation);
}